home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 3 / Cream of the Crop 3.iso / clipper / ks94an.zip / AHIGHELE.HDR < prev    next >
Text File  |  1994-04-25  |  1KB  |  52 lines

  1. /******************************************************************************
  2.                  The Klipper Library, for CA-Clipper 5.x
  3.         Copyright (c), 1994, Wallace Information Systems Engineering
  4.  
  5. FUNCTION:
  6.  
  7. _AHighElement( axArray ) --> nHighElement
  8.  
  9. PARAMETERS:
  10.  
  11. axArray : array of CHAR, DATE, or NUM elements
  12.  
  13.  
  14. SHORT:
  15.  
  16. Find element with highest numeric, char or date value.
  17.  
  18. DESCRIPTION:
  19.  
  20. _AHighElement() returns the element number associated with the highest
  21. value from an array of Character Strings, Dates or Numerics.
  22.  
  23. ALL elements must be of the same type!
  24.  
  25. If the array contains mixed elements, a run-time error will occur. If the
  26. array in not CHAR, DATE, or NUM, the return value is NIL.
  27.  
  28. NOTE:
  29.  
  30. See also:
  31.  
  32. _ALowVal() which returns the lowest value.
  33.  
  34. _AHighVal() which returns the highest value.
  35.  
  36. _ALowElement() which returns the element number associated with the
  37. lowest value.
  38.  
  39. EXAMPLE:
  40.  
  41. LOCAL aArray := { 1,5,3,9,12,7 }
  42. t = _AHighElement( aArray )
  43.  
  44. Result: t = 5
  45.  
  46. LOCAL aArray := { 'Wallace', 'Jones', 'Taylor', 'Abdul'  }
  47. t = _AHighElement( aArray )
  48.  
  49. Result: t = 1
  50.  
  51. ******************************************************************************/
  52.